﻿using System;

namespace Sigil.NonGeneric
{
	public partial class Emit
	{
		/// <summary>
		/// Converts a TypedReference on the stack into a reference to the contained Object, given the type contained in the TypedReference.
		///
		/// __makeref(Int32) on the stack would become an Int32&amp;, for example.
		/// </summary>
		public Emit ReferenceAnyValue<Type>()
		{
			InnerEmit.ReferenceAnyValue<Type>();
			return this;
		}

		/// <summary>
		/// Converts a TypedReference on the stack into a reference to the contained Object, given the type contained in the TypedReference.
		///
		/// __makeref(Int32) on the stack would become an Int32&amp;, for example.
		/// </summary>
		public Emit ReferenceAnyValue(Type type)
		{
			InnerEmit.ReferenceAnyValue(type);
			return this;
		}
	}
}